<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        * {
            margin: 0;
            padding: 0;
        }
        
        .box {
            /* width: 1200px; */
            width: 80%;
            height: 200px;
            background-color: #ccc;
            margin: 50px auto;
            /* 给父元素设置为flex布局 */
            display: flex;
            /* 设置主轴的方向 默认的主轴方向是水平方向 */
            /* flex-direction: column; */
            /* flex-direction: row; */
            /* flex-direction: row-reverse; */
            /* flex-direction: column-reverse; */
            /* justify-content: flex-start; */
            /* justify-content: flex-end; */
            /* justify-content: center; */
            /* 设置主轴上子元素的排列方式   space-around 剩余空间等均分 */
            /* justify-content: space-around; */
            /* justify-content: space-between; */
            /* justify-content: space-evenly; */
            /* flex-wrap: nowrap; */
            /* flex-wrap: wrap; */
            /* 设置子元素是否换行  默认的是不换行 */
            /* flex-wrap: wrap-reverse; */
            /* align-items: flex-end; */
            /* align-items: center; */
            /* align-items: space-around; */
            /* align-items: space-between; */
            /* align-items: stretch; */
            /* flex-wrap: wrap; */
            /* 设置侧轴上子元素的排列方式 单行 */
            /* align-items: space-around; */
            /* align-items: space-between; */
            /* align-content: space-around; */
            /* 设置侧轴上子元素的排列方式 多行 */
            /* align-content: space-between; */
            /* flex-direction: column; */
            /* align-items: center; */
            /* justify-content: center; */
            /* flex-wrap: wrap; */
            /* flex-flow: column wrap; */
            /* flex-flow: wrap column;
            align-content: space-around; */
        }
        
        .box div {
            width: 200px;
            /* height: 100px; */
            flex: 1;
            background-color: #ff3040;
        }
        
        .box .two {
            background-color: yellow;
            /* 所占份数 */
            flex: 2;
            /* flex-grow: ;
            flex-shrink: ;
            flex-basis: ; */
            /* 设置子元素自己在侧轴上的排列方式 */
            /* align-self: center; */
            /* 设置元素的排列方式 值是数值类型  默认是0  数值越小越靠前 */
            order: -1;
        }
        
        .box .three {
            background-color: blueviolet;
            order: -2;
        }
    </style>
</head>

<body>
    <div class="box">
        <div class="one">1</div>
        <div class="two">2</div>
        <div class="three">3</div>
        <!-- <div class="one">1</div>
        <div class="two">2</div>
        <div class="three">3</div>
        <div class="one">1</div>
        <div class="two">2</div>
        <div class="three">3</div> -->
    </div>
</body>

</html>